package com.mikelouis.test.scala.proginscala.chapter27.recipe

/**
 * Created by yuazhu on 2/25/2015.
 */
object SimpleBrowser extends Browser {
  val database = SimpleDatabase

  def main(args: Array[String]) {
    val apple = SimpleDatabase.foodNamed("Apple").get
    println(recipesUsing(apple))
  }
}

//object SimpleBrowser {
//  def recipesUsing(food: Food) =
//    SimpleDatabase.allRecipes.filter(recipe =>
//      recipe.ingredients.contains(food))
//
//  def main(args: Array[String]) {
//    val apple = SimpleDatabase.foodNamed("Apple").get
//    recipesUsing(apple)
//  }
//}